var express = require('express');
var app = express();

app.set('views', __dirname + '/views'); // set views directory
app.engine('html', require('ejs').renderFile); // make ejs render .html files

app.use(express.json());       // to support JSON-encoded bodies
app.use(express.urlencoded()); // to support URL-encoded bodies

app.use(express.cookieParser()); // need to support sessions
app.use(express.session({secret: 'super duper secret'}));

//var db = require('./middleware/connection.js').db();
//db.connect();
var game = require('./middleware/game.js');
require('./routes')(app); // require routes


var MaxPlayers = 2000;
tick = 0;
var drifted = 'false';
 var loop =  setInterval(function() { 
 	
},1000);






app.listen(3000);



